#define _USE_MATH_DEFINES
#define _CRT_SECURE_NO_WARNINGS

#include <algorithm>
#include <bitset>
#include <cassert>
#include <cfloat>
#include <cmath>
#include <complex>
#include <cstdio>
#include <ctime>
#include <deque>
#include <fstream>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <sstream>
#include <string>
#include <utility>
#include <vector>
using namespace std;

#define all(x) (x).begin(),(x).end()
typedef long long ll;
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
typedef vector<int> VI;
typedef vector<string> VS;
typedef vector<VI> VVI;
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
typedef pair<int,int> PII;
typedef vector<PII> VPII;
#define X first
#define Y second
#define mp make_pair
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
#define two(x) (1<<(x))
#define twoll(x) ((long long)1<<(x))
#define contain(s,x) (((s)&two(x))!=0)
#define containll(s,x) (((s)&twoll(x))!=0)
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
#define db(a) cout << #a << "=" << a << " "
#define dbn cout << endl
#define dbs(str) cout << str
template<class T> void print(vector<T> v) { cout << "["; if (v.size()) cout << v[0]; for (unsigned i = 1; i < v.size(); i++) cout << ", " << v[i];cout << "]\n"; }
template<class T> void print(vector<vector<T> > v) { cout << "[ ---\n"; if (v.size()) cout << " ", print(v[0]); for (unsigned i = 1; i < v.size(); i++) cout << " ", print(v[i]); cout << "--- ]\n"; }
template<class T1, class T2> void print(pair<T1,T2> p) { cout << "{" << p.first << ", " << p.second << "}"; }
template<class T1, class T2> void print(vector<pair<T1,T2> > v) { cout << "["; if (v.size()) print(v[0]); for (unsigned i = 1; i < v.size(); i++) cout << ", ", print(v[i]);cout << "]\n"; }
template<class T> inline T sqr(T x) { return x*x; }
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
template<class T> inline int chkmin(T& a, T b) { if (a>b) {a=b; return 1;} return 0; }
template<class T> inline int chkmax(T& a, T b) { if (a<b) {a=b; return 1;} return 0; }
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
string STR(long long n) { char tmp[20]; lltoa(n,tmp,10); return string(tmp); }
long long LL(string s) { return atoll(s.c_str()); }
template <class Ty, class Tx> Ty to(const Tx &x) { Ty y; stringstream ss; ss<<x; ss>>y; return y; }
// BEGIN CUT HERE
// END CUT HERE
// BEGIN CUT HERE
const int INF = 1000000007;
const double EPS = 1e-10;
// BEGIN CUT HERE
#define TESTCASE 
// END CUT HERE

struct Time
{
	string whatTime(int seconds)
	{
		int h, m, s;
		int sec = seconds;
		h = sec / 3600;
		sec = sec % 3600;
		m = sec / 60;
		sec = sec % 60;
		s = sec;
		char buf[100];
		sprintf(buf, "%d:%d:%d", h, m , s);
		return buf;
	}
};

// BEGIN CUT HERE
namespace moj_harness {
	int run_test_case(int);
	void run_test(int casenum = -1, bool quiet = false) {
		if ( casenum != -1 ) {
			if ( run_test_case( casenum ) == -1 && !quiet )
				cerr << "Illegal input! Test case " << casenum << " does not exist." << endl;
			return;
		}
		
		int correct = 0, total = 0;
		for ( int i=0;; ++i ) {
			int x = run_test_case(i);
			if ( x == -1 ) {
				if ( i >= 100 ) break;
				continue;
			}
			correct += x;
			++total;
		}
		
		if ( total == 0 ) {
			cerr << "No test cases run." << endl;
		} else if ( correct < total ) {
			cerr << "Some cases FAILED (passed " << correct << " of " << total << ")." << endl;
		} else {
			cerr << "All " << total << " tests passed!" << endl;
		}
	}
	
	int verify_case(int casenum, const string &expected, const string &received, clock_t elapsed) { 
		cerr << "Example " << casenum << "... "; 
		
		string verdict;
		vector<string> info;
		char buf[100];
		
		if (elapsed > CLOCKS_PER_SEC / 200) {
			sprintf(buf, "time %.2fs", elapsed * (1.0/CLOCKS_PER_SEC));
			info.push_back(buf);
		}
		
		if ( expected == received ) {
			verdict = "PASSED";
		} else {
			verdict = "FAILED";
		}
		
		cerr << verdict;
		if (!info.empty()) {
			cerr << " (";
			for (int i=0; i<(int)info.size(); ++i) {
				if (i > 0) cerr << ", ";
				cerr << info[i];
			}
			cerr << ")";
		}
		cerr << endl;
		
		if (verdict == "FAILED") {
			cerr << "    Expected: \"" << expected << "\"" << endl; 
			cerr << "    Received: \"" << received << "\"" << endl; 
		}
		
		return verdict == "PASSED";
	}

	int run_test_case( int casenum ) {
		switch( casenum ) {
		case 0: {
			int seconds               = 0;
			string expected__         = "0:0:0";

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}
		case 1: {
			int seconds               = 3661;
			string expected__         = "1:1:1";

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}
		case 2: {
			int seconds               = 5436;
			string expected__         = "1:30:36";

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}
		case 3: {
			int seconds               = 86399;
			string expected__         = "23:59:59";

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}

		// custom cases

/*      case 4: {
			int seconds               = ;
			string expected__         = ;

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}*/
/*      case 5: {
			int seconds               = ;
			string expected__         = ;

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}*/
/*      case 6: {
			int seconds               = ;
			string expected__         = ;

			clock_t start__           = clock();
			string received__         = Time().whatTime( seconds );
			return verify_case( casenum, expected__, received__, clock()-start__ );
		}*/
		default:
			return -1;
		}
	}
}


int main(int argc, char *argv[]) {
	freopen("DATA.in", "rt", stdin);
	freopen("DATA.ou", "wt", stdout);

	if (argc == 1) {
		moj_harness::run_test(TESTCASE);
	} else {
		for (int i=1; i<argc; ++i)
			moj_harness::run_test(atoi(argv[i]));
	}

	return 0;
}
// END CUT HERE
